﻿using System;
using System.Text;
using System.Collections.Generic;
using System.Data;
using BCDto.MySql.BusinessFlowStepInstance;
using BCCommon.OAEnums;
using BCCommon.Extensions;

namespace BCDto.MySql.BusinessFlowInstance
{
    /// <summary>
    /// OA系统业务流实例
    /// </summary>
    public class BusinessFlowInstanceDto
    {
        /// <summary>
        /// OA系统业务流实例Id
        /// </summary>		
        public long BusinessFlowInstanceId { get; set; }
        /// <summary>
        /// OA系统业务流实例名称
        /// </summary>		
        public string BusinessFlowInstanceName { get; set; }
        /// <summary>
        /// OA系统业务流模型Id
        /// </summary>		
        public long BusinessFlowModelId { get; set; }
        /// <summary>
        /// 业务流模型名称
        /// </summary>		
        public string BusinessFlowModelName { get; set; }
        /// <summary>
        /// 业务流模型编码
        /// </summary>		
        public string BusinessFlowModelCode { get; set; }
        /// <summary>
        /// OA系统业务流分类Id
        /// </summary>		
        public long BusinessFlowCategoryId { get; set; }
        /// <summary>
        /// OA系统业务流分类名称
        /// </summary>		
        public string BusinessFlowCategoryName { get; set; }
        /// <summary>
        /// 业务级别
        /// </summary>
        public OARelatedBusinessTaskLevel BusinessTaskLevel { get; set; }
        /// <summary>
        /// 业务级别
        /// </summary>
        /// <returns></returns>
        public string BusinessTaskLevelStr ()=> this.BusinessTaskLevel.GetDescriptionString();
        /// <summary>
        /// 公司Id
        /// </summary>		
        public int CompanyId { get; set; }
        /// <summary>
        /// 公司名称
        /// </summary>		
        public string CompanyName { get; set; }
        /// <summary>
        /// 业务总步骤
        /// </summary>		
        public int TotalStep { get; set; }
        /// <summary>
        /// 当前步骤
        /// </summary>		
        public int CurrentlyStep { get; set; }
        /// <summary>
        /// 创建时间
        /// </summary>		
        public DateTime CreateTime { get; set; }
        /// <summary>
        /// 是否为集团业务
        /// </summary>
        public bool IsGroupBusiness { get; set; }
        /// <summary>
        /// 已关闭
        /// </summary>
        public bool IsClosed { get; set; }
        /// <summary>
        /// 关闭备注
        /// </summary>
        public string ClosedRemark { get; set; }
        /// <summary>
        /// 关闭人Id
        /// </summary>
        public long? CloseAdminId { get; set; }
        /// <summary>
        /// 关闭人姓名
        /// </summary>
        public string CloseAdminName { get; set; }
        /// <summary>
        /// 关闭时间
        /// </summary>
        public DateTime? CloseTime { get; set; }
        /// <summary>
        /// 业务流步骤实例列表
        /// </summary>
        public List<BusinessFlowStepInstanceDto> Steps { get; set; }
    }
}

